import { fetchRequestHandler } from "@trpc/server/adapters/fetch"; import { appRouter } from "@/server/router"; import { createContext } from "@/server/context"; export const revalidate = 0; export const dynamic = "force-dynamic"; const handler = (req: Request) => fetchRequestHandler({ endpoint: "/api", req, router: appRouter, createContext, }); export { handler as GET, handler as POST };